package timbap.visualizer.api.context.messaging;

/**
 * The <code>MessagingManager</code> interface is the base
 * interface for all classes that need to send a message
 * to an external program. It is usable with any messaging
 * provider that uses named topics and can send string data.
 *
 * @author  Andreas Pabst
 */
public interface MessagingManager<T> {

    /**
     * sets the messaging provider to be used
     * 
     * @param pMessagingProvider	the messaging provider
     */
    public void setMessagingProvider(T pMessagingProvider);

    /**
     * sends a message to a topic using the
     * respective messaging provider
     * 
     * @param pTopic	the name of the topic to send to
     * @param pMessage	the string message to send
     */
    public void sendStringMessage(String pTopic, String pMessage);

}
